home *** CD-ROM | disk | FTP | other *** search
/ AmigActive 26 / AACD 26.iso / AACD / Online / PHP / include / php / ext / standard / php_array.h < prev    next >
Encoding:
C/C++ Source or Header  |  2001-03-12  |  3.5 KB  |  107 lines

  1. /* 
  2.    +----------------------------------------------------------------------+
  3.    | PHP version 4.0                                                      |
  4.    +----------------------------------------------------------------------+
  5.    | Copyright (c) 1997-2001 The PHP Group                                |
  6.    +----------------------------------------------------------------------+
  7.    | This source file is subject to version 2.02 of the PHP license,      |
  8.    | that is bundled with this package in the file LICENSE, and is        |
  9.    | available at through the world-wide-web at                           |
  10.    | http://www.php.net/license/2_02.txt.                                 |
  11.    | If you did not receive a copy of the PHP license and are unable to   |
  12.    | obtain it through the world-wide-web, please send a note to          |
  13.    | license@php.net so we can mail you a copy immediately.               |
  14.    +----------------------------------------------------------------------+
  15.    | Authors: Andi Gutmans <andi@zend.com>                                |
  16.    |          Zeev Suraski <zeev@zend.com>                                |
  17.    |          Rasmus Lerdorf <rasmus@php.net>                             |
  18.    |          Andrei Zmievski <andrei@ispi.net>                           |
  19.    +----------------------------------------------------------------------+
  20. */
  21.  
  22. /* $Id: php_array.h,v 1.22 2001/03/12 03:06:53 andrei Exp $ */
  23.  
  24. #ifndef PHP_ARRAY_H
  25. #define PHP_ARRAY_H
  26.  
  27. PHP_MINIT_FUNCTION(array);
  28. PHP_MSHUTDOWN_FUNCTION(array);
  29.  
  30. PHP_FUNCTION(ksort);
  31. PHP_FUNCTION(krsort);
  32. PHP_FUNCTION(natsort);
  33. PHP_FUNCTION(natcasesort);
  34. PHP_FUNCTION(asort);
  35. PHP_FUNCTION(arsort);
  36. PHP_FUNCTION(sort);
  37. PHP_FUNCTION(rsort);
  38. PHP_FUNCTION(usort);
  39. PHP_FUNCTION(uasort);
  40. PHP_FUNCTION(uksort);
  41. PHP_FUNCTION(array_walk);
  42. PHP_FUNCTION(count);
  43. PHP_FUNCTION(end);
  44. PHP_FUNCTION(prev);
  45. PHP_FUNCTION(next);
  46. PHP_FUNCTION(reset);
  47. PHP_FUNCTION(current);
  48. PHP_FUNCTION(key);
  49. PHP_FUNCTION(min);
  50. PHP_FUNCTION(max);
  51. PHP_FUNCTION(in_array);
  52. PHP_FUNCTION(array_search);
  53. PHP_FUNCTION(extract);
  54. PHP_FUNCTION(compact);
  55. PHP_FUNCTION(range);
  56. PHP_FUNCTION(shuffle);
  57. PHP_FUNCTION(array_multisort);
  58. PHP_FUNCTION(array_push);
  59. PHP_FUNCTION(array_pop);
  60. PHP_FUNCTION(array_shift);
  61. PHP_FUNCTION(array_unshift);
  62. PHP_FUNCTION(array_splice);
  63. PHP_FUNCTION(array_slice);
  64. PHP_FUNCTION(array_merge);
  65. PHP_FUNCTION(array_merge_recursive);
  66. PHP_FUNCTION(array_keys);
  67. PHP_FUNCTION(array_values);
  68. PHP_FUNCTION(array_count_values);
  69. PHP_FUNCTION(array_reverse);
  70. PHP_FUNCTION(array_reduce);
  71. PHP_FUNCTION(array_pad);
  72. PHP_FUNCTION(array_flip);
  73. PHP_FUNCTION(array_rand);
  74. PHP_FUNCTION(array_unique);
  75. PHP_FUNCTION(array_intersect);
  76. PHP_FUNCTION(array_diff);
  77. PHP_FUNCTION(array_sum);
  78.  
  79. HashTable* php_splice(HashTable *, int, int, zval ***, int, HashTable **);
  80. PHPAPI void php_array_merge(HashTable *dest, HashTable *src, int recursive);
  81. int multisort_compare(const void *a, const void *b);
  82.  
  83. typedef struct {
  84.     int *multisort_flags[2];
  85.     int (*compare_func)(zval *result, zval *op1, zval *op2);
  86. } php_array_globals;
  87.  
  88. #ifdef ZTS
  89. #define ARRAYLS_D php_array_globals *array_globals
  90. #define ARRAYLS_DC , ARRAYLS_D
  91. #define ARRAYLS_C array_globals
  92. #define ARRAYLS_CC , ARRAYLS_C
  93. #define ARRAYG(v) (array_globals->v)
  94. #define ARRAYLS_FETCH() php_array_globals *array_globals = ts_resource(array_globals_id)
  95. extern int array_globals_id;
  96. #else
  97. #define ARRAYLS_D
  98. #define ARRAYLS_DC
  99. #define ARRAYLS_C
  100. #define ARRAYLS_CC
  101. #define ARRAYG(v) (array_globals.v)
  102. #define ARRAYLS_FETCH()
  103. extern php_array_globals array_globals;
  104. #endif
  105.  
  106. #endif /* PHP_ARRAY_H */
  107.